<?php

/**
 * view actions.
 *
 * @package    phpmymovies
 * @subpackage view
 * @author     Your name here
 * @version    SVN: $Id: actions.class.php 12479 2008-10-31 10:54:40Z fabien $
 */
class viewActions extends sfActions
{
 /**
  * Executes index action
  *
  * @param sfRequest $request A request object
  */
  public function executeIndex(sfWebRequest $request)
  {
    
  }
  /**
  * Show movies recent added
  *
  * @param sfRequest $request A request object
  */
  public function executeRecent(sfWebRequest $request)
  {
	//Object to do the query
    $c = new Criteria();
	//Number of movies to retrieve
	$limit = 10;
	$c->addDescendingOrderByColumn(MoviePeer::ID);
	$c->setLimit($limit);
	$this->movies = MoviePeer::doSelect($c);
  }
}
